{include file=$header}
<div id="content">
{if $smarty.session.logged eq 1}
 <h1>{$titlePage}{$smarty.session.user}</h1>
  <a href="{$smarty.const.AGENDA}/insert">Novo Contato</a>
  <table>
  	<tr>
     <th>Nome</th>
     <th>Celular</th>
     <th>Email</th>
     <th>Ações</th>
    </tr>
{foreach from=$lista item=row}  
    <tr>
     <td><a href="{$smarty.const.AGENDA}/perfil/{$row['id_contact']}">{$row['name']}</a></td>
     <td>{$row['cel']}</td>
     <td>{$row['email']}</td>
     <td>
      <a href="{$smarty.const.AGENDA}/edit/{$row['id_contact']}">Edit</a> |
      <a href="{$smarty.const.AGENDA}/delete/{$row['id_contact']}">Delete</a>
     </td>
    </tr>
{/foreach}    
  </table>
  <p>{$msgDelete}</p>
{else}
<p>{$msgLogin}</p>
{/if} 
{include file=$footer}